/*
 * simes - simulador de escalonamento de processos
 * Copyright (C) 2006  Pablo A. Lerina Rodrigues
 *                     Armando Zaro
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 */

#ifndef __SIMES_H__
#define __SIMES_H__

#include "stack.h"
#include "queue.h"
#include "colors.h"

#define TAM_LINHA 256

#ifndef INLINE
#define INLINE inline
#endif

typedef char *string;
typedef string *vstring;


// COMANDOS
#define PROCESSA 1
#define DORME 2
#define ADQUIRE 3
#define LIBERA 4
#define FIM 5

// ESTADOS
#define P 1 // processa
#define E 2 // espera
#define D 3 // dorme
char *estados[] = {"p", "e", "d"};

inline int id_cmd();
void le_comandos();

#endif
